<?php 
/**
 * Date format
 */
$date = "Apr-22-2014 7:00 pm";
//echo date('D, F d @ g:ia ', strtotime($date)); 

$date = '2012-12-25';
//echo date('d-m-Y', strtotime($date));

$date = "2014-12-25";
$time = mktime(0, 0, 0, 12, 25, 2014);
// echo date('d-m-Y', strtotime($date));

$date = new Datetime('25-12-2012');
//echo $date->format('Y-d-m');


/**
 * Add date
 */
$date = new DateTime('2012-12-25');
$date->modify('+2 days');
echo $date->format('Y-m-d');


/**
 * Timestamp to date
 */
date('Y-m-d', $time_stamp);
